<!--
 * @Author: tlm
 * @Date: 2020-06-29 15:22:59
 * @LastEditTime: 2020-07-01 16:25:32
 * @LastEditors: tlm
 * @Description: 
 * @FilePath: \S3DV_WipSurfer\src\components\view\viewTreeMain.vue
 * @support by tlm
--> 
<template>
  <div class="viewTreeMain">
    <hsc-window-style-metal>
      <hsc-window
        title="Model Tree"
        :closeButton="true"
        :resizable="true"
        :isOpen.sync="isOpen"
        :minWidth="150"
        :minHeight="200"
        :maxWidth="500"
        :maxHeight="680"
        :width.sync="width" 
        :height.sync="height"
        :positionHint="positionHint"
        style="textAlign:left"
      >
        <el-scrollbar style="height:100%" :wrapStyle="[{'overflow-x':'hidden'}]">
            <viewModelTree></viewModelTree>
        </el-scrollbar>
      </hsc-window>
    </hsc-window-style-metal>
  </div>
</template>

<script>
import ComponentSignals from "@/utils/componentSignals";
import viewModelTree from "@/components/view/tree/viewModelTree.vue";

let defaultWidth = document.body.clientWidth / 4;
let defaultHeight = (document.documentElement.clientHeight * 2) / 3;
export default {
  name: "viewTreeMain",
  data() {
    return {
      isOpen: false,
      width: defaultWidth,
      height: defaultHeight,
      positionHint:'0/0'
    };
  },
  components: {
    viewModelTree
  },
  created() {},
  mounted() {
      ComponentSignals.showTree.add(() => {
      this.isOpen = !this.isOpen;
    });
  },
  methods: {}
};
</script>
<style lang='scss' scoped>
</style>
